package cn.zc.auth.service.controller;


import cn.tools.core.base.R;

import cn.zc.auth.service.service.StudentAndClassifyService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import cn.zc.auth.feign.entity.StudentAndClassify;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * <p>
 * 学生所报名的学科 前端控制器
 * </p>
 *
 * @author keno
 * @since 2022-02-12
 */
@Api(tags = "学生报名学科")
@RestController
@RequestMapping("/auth")
public class StudentAndClassifyController {

    @Resource
    private StudentAndClassifyService studentAndClassifyService;

    /**
     * 通过学生id查询出学生报名了那几科学业
     * @param studentId
     * @return
     */
    @ApiOperation(value = "查询出学生报名了那些学业")
    @GetMapping("/getStudentAndClassify")
    private R<Object> getStudentAndClassify(String studentId){
        StudentAndClassify studentAndClassify = studentAndClassifyService.getStudentAndClassify(studentId);
        return R.success(studentAndClassify);
    }
}

